﻿<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="Default.aspx.cs" Inherits="BabyOffice.Default" %>

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">

<html xmlns="http://www.w3.org/1999/xhtml">
<head runat="server">
    <title></title>
</head>
<body style="font-size:12px">
    <form id="form1" runat="server">
    <div style="width:100%">
        <div>
            <asp:FileUpload ID="fileUpload" runat="server" Width="500px"/>
            <asp:Button ID="btnUpload" runat="server" Text="上传" onclick="btnUpload_Click" />
        </div>
        <table style="width:100%">
            <tr>                
                <td>
                    <asp:GridView ID="gvFiles" runat="server" AutoGenerateColumns="False" 
                        DataKeyNames="FileFullName" CellPadding="4" ForeColor="#333333" 
                        GridLines="None" onrowcommand="gvFiles_RowCommand">
                        <AlternatingRowStyle BackColor="White" ForeColor="#284775" />
                        <Columns>
                            <asp:BoundField HeaderText="文件名" DataField="FileName" />
                            <asp:BoundField HeaderText="上传时间" DataField="CreationTime" />  
                            <asp:TemplateField HeaderText="操作">
                                <ItemTemplate>
                                    <asp:LinkButton ID="lBtnSelect" runat="server" CommandName="selectFile">选择</asp:LinkButton>
                                    <asp:LinkButton ID="lBtnDelete" runat="server" OnClientClick="return confirm('确定要删除该文件吗？');" CommandName="deleteFile">删除</asp:LinkButton>
                                </ItemTemplate>
                            </asp:TemplateField>                          
                        </Columns>
                        <EditRowStyle BackColor="#999999" />
                        <FooterStyle BackColor="#5D7B9D" Font-Bold="True" ForeColor="White" />
                        <HeaderStyle BackColor="#5D7B9D" Font-Bold="True" ForeColor="White" />
                        <PagerStyle BackColor="#284775" ForeColor="White" HorizontalAlign="Center" />
                        <RowStyle BackColor="#F7F6F3" ForeColor="#333333" />
                        <SelectedRowStyle BackColor="#E2DED6" Font-Bold="True" ForeColor="#333333" />
                        <SortedAscendingCellStyle BackColor="#E9E7E2" />
                        <SortedAscendingHeaderStyle BackColor="#506C8C" />
                        <SortedDescendingCellStyle BackColor="#FFFDF8" />
                        <SortedDescendingHeaderStyle BackColor="#6F8DAE" />
                        <EmptyDataTemplate>
                            <div>服务器上没有已上传的文件。</div>
                        </EmptyDataTemplate>
                    </asp:GridView>
                </td>
                <td>
                    <asp:CheckBoxList ID="cblSheets" runat="server">
                    </asp:CheckBoxList>                
                </td>
            </tr>
        </table>
    </div>
    </form>
</body>
</html>
